package com.github_dididipapa.common.exception;


/*
* 状态码枚举类
* */
public enum BizCodeEnume {
    UNKNOW_EXCEPTION(10000,"系统未知异常"),
    VALID_EXCEPTION(10001,"参数格式校验失败"),
    ATTRIBUTE_NOT_EXIST_EXCEPTION(10002,"对应属性不存在"),
    ATTRIBUTE_BOUND_REPEATEDLY_EXCEPTION(10003,"属性值重复绑定"),
    PRODUCT_UP_EXCEPTION(11000,"商品上架异常"),
    USER_EXIST_EXCEPTION(15001,"用户已存在"),
    USER_PASSWORD_WRONG_EXCEPTION(15002,"密码错误"),
    USER_NOT_LOGIN_EXCEPTION(15003,"用户未登录"),
    USER_LOGIN_EXCEPTION(15004,"用户登录异常");

    private int code;
    private String msg;
    BizCodeEnume() {}

    BizCodeEnume(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public int getCode() {
        return code;
    }
    public String getMsg() {
        return msg;
    }
}
